package com.iwayin.core.dataobject;

import java.util.Date;

import com.iwayin.core.utils.DateTimeUtil;
import com.iwayin.core.utils.PageInfo;

/**
 * 
 * @author LIUWENLONG
 * 
 */
public class NotificationDO extends PageInfo {

	private static final long serialVersionUID = 1849008528357947686L;

	public static final Long TYPE_FANS = 1L;
	public static final Long TYPE_VOTE = 2L;
	public static final Long TYPE_COMMENT = 3L;

	private Long id;
	private Long userId;
	private Long objectId;
	private Long type;
	private String body;
	private Integer status;
	private Date createtime;

	private Long fromUserId;
	private String avatarPath;
	private String nickName;

	public Long getId() {
		return id;
	}

	public Long getUserId() {
		return userId;
	}

	public Long getObjectId() {
		return objectId;
	}

	public Long getType() {
		return type;
	}

	public String getBody() {
		return body;
	}

	public Integer getStatus() {
		return status;
	}

	public Date getCreatetime() {
		return createtime;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public void setUserId(Long userId) {
		this.userId = userId;
	}

	public void setObjectId(Long objectId) {
		this.objectId = objectId;
	}

	public void setType(Long type) {
		this.type = type;
	}

	public void setBody(String body) {
		this.body = body;
	}

	public void setStatus(Integer status) {
		this.status = status;
	}

	public void setCreatetime(Date createtime) {
		this.createtime = createtime;
	}

	public String getAvatarPath() {
		return avatarPath;
	}

	public String getNickName() {
		return nickName;
	}

	public String getHistory() {
		if(createtime!=null){
			return DateTimeUtil.getFormatDateTime_CN(createtime);
		}
		return "";
	}

	public void setAvatarPath(String avatarPath) {
		this.avatarPath = avatarPath;
	}

	public void setNickName(String nickName) {
		this.nickName = nickName;
	}

	public Long getFromUserId() {
		return fromUserId;
	}

	public void setFromUserId(Long fromUserId) {
		this.fromUserId = fromUserId;
	}

}